using DataDynamics.ActiveReports;
using DataDynamics.ActiveReports.Export.Xls;
using SS;
using System;
using System.ComponentModel;
using System.Data;
using System.Data.SqlClient;
using System.Drawing;
using System.Windows.Forms;
using TVSBH.func;
namespace TVSGPP.func
{
	public class frmTraceQuantity : Form
	{
		private IContainer components = null;
		private Button btnDelete;
		private Button btnAdd;
		private Button btnClose;
		private DataGridView dgvProduct;
		private System.Windows.Forms.Label label1;
		private System.Windows.Forms.Label label2;
		private System.Windows.Forms.Label label3;
		private System.Windows.Forms.Label label4;
		private System.Windows.Forms.Label label5;
		private System.Windows.Forms.Label label6;
		private System.Windows.Forms.Label label7;
		private System.Windows.Forms.Label label8;
		private System.Windows.Forms.Label label9;
		private System.Windows.Forms.Label label10;
		private Button btnPrint;
		private Button btnExportToExcel;
		private DataGridViewTextBoxColumn DateInput;
		private DataGridViewTextBoxColumn Row_Index;
		private DataGridViewTextBoxColumn productName;
		private DataGridViewTextBoxColumn unitName;
		private DataGridViewTextBoxColumn Name1;
		private DataGridViewTextBoxColumn Packet;
		private DataGridViewTextBoxColumn ProductExpiryDate;
		private DataGridViewTextBoxColumn Comnent;
		private DataGridViewTextBoxColumn Note;
		private DataGridViewTextBoxColumn Pid;
		private DataGridViewTextBoxColumn Column1;
		private Func objFunc = new Func();
		private string strConnection = "";
		private string currPid = "";
		private string currPacket = "";
		public string userName = "";
		private DataTable objTable;
		protected override void Dispose(bool disposing)
		{
			if (disposing && this.components != null)
			{
				this.components.Dispose();
			}
			base.Dispose(disposing);
		}
		private void InitializeComponent()
		{
			DataGridViewCellStyle dataGridViewCellStyle = new DataGridViewCellStyle();
			DataGridViewCellStyle dataGridViewCellStyle2 = new DataGridViewCellStyle();
			DataGridViewCellStyle dataGridViewCellStyle3 = new DataGridViewCellStyle();
			this.btnDelete = new Button();
			this.btnAdd = new Button();
			this.btnClose = new Button();
			this.dgvProduct = new DataGridView();
			this.label1 = new System.Windows.Forms.Label();
			this.label2 = new System.Windows.Forms.Label();
			this.label3 = new System.Windows.Forms.Label();
			this.label4 = new System.Windows.Forms.Label();
			this.label5 = new System.Windows.Forms.Label();
			this.label6 = new System.Windows.Forms.Label();
			this.label7 = new System.Windows.Forms.Label();
			this.label8 = new System.Windows.Forms.Label();
			this.label9 = new System.Windows.Forms.Label();
			this.label10 = new System.Windows.Forms.Label();
			this.btnPrint = new Button();
			this.btnExportToExcel = new Button();
			this.DateInput = new DataGridViewTextBoxColumn();
			this.Row_Index = new DataGridViewTextBoxColumn();
			this.productName = new DataGridViewTextBoxColumn();
			this.unitName = new DataGridViewTextBoxColumn();
			this.Name1 = new DataGridViewTextBoxColumn();
			this.Packet = new DataGridViewTextBoxColumn();
			this.ProductExpiryDate = new DataGridViewTextBoxColumn();
			this.Comnent = new DataGridViewTextBoxColumn();
			this.Note = new DataGridViewTextBoxColumn();
			this.Pid = new DataGridViewTextBoxColumn();
			this.Column1 = new DataGridViewTextBoxColumn();
			((ISupportInitialize)this.dgvProduct).BeginInit();
			base.SuspendLayout();
			this.btnDelete.Anchor = (AnchorStyles.Bottom | AnchorStyles.Left);
			this.btnDelete.Font = new Font("Arial", 9f, FontStyle.Bold, GraphicsUnit.Point, 163);
			this.btnDelete.Location = new Point(113, 564);
			this.btnDelete.Name = "btnDelete";
			this.btnDelete.Size = new Size(96, 30);
			this.btnDelete.TabIndex = 69;
			this.btnDelete.Text = "Xoá mục [ F8 ]";
			this.btnDelete.UseVisualStyleBackColor = true;
			this.btnDelete.Click += new EventHandler(this.btnDelete_Click);
			this.btnAdd.Anchor = (AnchorStyles.Bottom | AnchorStyles.Left);
			this.btnAdd.Font = new Font("Arial", 9f, FontStyle.Bold, GraphicsUnit.Point, 163);
			this.btnAdd.Location = new Point(6, 564);
			this.btnAdd.Name = "btnAdd";
			this.btnAdd.Size = new Size(105, 30);
			this.btnAdd.TabIndex = 68;
			this.btnAdd.Text = "Thêm mới [ F4 ]";
			this.btnAdd.UseVisualStyleBackColor = true;
			this.btnAdd.Click += new EventHandler(this.btnAdd_Click);
			this.btnClose.Anchor = (AnchorStyles.Bottom | AnchorStyles.Right);
			this.btnClose.Font = new Font("Arial", 9f, FontStyle.Bold, GraphicsUnit.Point, 163);
			this.btnClose.Location = new Point(802, 564);
			this.btnClose.Name = "btnClose";
			this.btnClose.Size = new Size(91, 30);
			this.btnClose.TabIndex = 67;
			this.btnClose.Text = "Thoát [ ESC ]";
			this.btnClose.UseVisualStyleBackColor = true;
			this.btnClose.Click += new EventHandler(this.btnClose_Click);
			this.dgvProduct.AllowUserToAddRows = false;
			this.dgvProduct.AllowUserToDeleteRows = false;
			this.dgvProduct.AllowUserToOrderColumns = true;
			this.dgvProduct.AllowUserToResizeColumns = false;
			this.dgvProduct.AllowUserToResizeRows = false;
			dataGridViewCellStyle.BackColor = Color.FromArgb(192, 255, 255);
			dataGridViewCellStyle.Font = new Font("Arial", 9.75f, FontStyle.Regular, GraphicsUnit.Point, 0);
			this.dgvProduct.AlternatingRowsDefaultCellStyle = dataGridViewCellStyle;
			this.dgvProduct.Anchor = (AnchorStyles.Top | AnchorStyles.Bottom | AnchorStyles.Left | AnchorStyles.Right);
			this.dgvProduct.BackgroundColor = Color.White;
			this.dgvProduct.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize;
			this.dgvProduct.ColumnHeadersVisible = false;
			this.dgvProduct.Columns.AddRange(new DataGridViewColumn[]
			{
				this.DateInput,
				this.Row_Index,
				this.productName,
				this.unitName,
				this.Name1,
				this.Packet,
				this.ProductExpiryDate,
				this.Comnent,
				this.Note,
				this.Pid,
				this.Column1
			});
			this.dgvProduct.Cursor = Cursors.Hand;
			this.dgvProduct.Location = new Point(7, 83);
			this.dgvProduct.MultiSelect = false;
			this.dgvProduct.Name = "dgvProduct";
			this.dgvProduct.ReadOnly = true;
			this.dgvProduct.RowHeadersVisible = false;
			this.dgvProduct.RowHeadersWidthSizeMode = DataGridViewRowHeadersWidthSizeMode.DisableResizing;
			this.dgvProduct.RowTemplate.DefaultCellStyle.Font = new Font("Arial", 9.75f, FontStyle.Regular, GraphicsUnit.Point, 0);
			this.dgvProduct.SelectionMode = DataGridViewSelectionMode.FullRowSelect;
			this.dgvProduct.Size = new Size(886, 474);
			this.dgvProduct.TabIndex = 71;
			this.dgvProduct.CellClick += new DataGridViewCellEventHandler(this.dgvProduct_CellClick);
			this.dgvProduct.CellEnter += new DataGridViewCellEventHandler(this.dgvProduct_CellEnter);
			this.label1.Anchor = (AnchorStyles.Top | AnchorStyles.Left | AnchorStyles.Right);
			this.label1.Font = new Font("Arial", 12f, FontStyle.Bold, GraphicsUnit.Point, 0);
			this.label1.Location = new Point(7, 13);
			this.label1.Name = "label1";
			this.label1.Size = new Size(886, 26);
			this.label1.TabIndex = 72;
			this.label1.Text = "SỔ KIỂM  SOÁT CHẤT LƯỢNG THUỐC";
			this.label1.TextAlign = ContentAlignment.MiddleCenter;
			this.label2.BorderStyle = BorderStyle.FixedSingle;
			this.label2.Font = new Font("Arial", 9f, FontStyle.Bold, GraphicsUnit.Point, 0);
			this.label2.Location = new Point(7, 48);
			this.label2.Name = "label2";
			this.label2.Size = new Size(86, 36);
			this.label2.TabIndex = 73;
			this.label2.Text = "Ngày";
			this.label2.TextAlign = ContentAlignment.MiddleCenter;
			this.label3.BorderStyle = BorderStyle.FixedSingle;
			this.label3.Font = new Font("Arial", 9f, FontStyle.Bold, GraphicsUnit.Point, 0);
			this.label3.Location = new Point(92, 48);
			this.label3.Name = "label3";
			this.label3.Size = new Size(51, 36);
			this.label3.TabIndex = 74;
			this.label3.Text = "STT";
			this.label3.TextAlign = ContentAlignment.MiddleCenter;
			this.label4.BorderStyle = BorderStyle.FixedSingle;
			this.label4.Font = new Font("Arial", 9f, FontStyle.Bold, GraphicsUnit.Point, 0);
			this.label4.Location = new Point(142, 48);
			this.label4.Name = "label4";
			this.label4.Size = new Size(151, 36);
			this.label4.TabIndex = 75;
			this.label4.Text = "Tên thuốc Hàm lượng Nồng độ";
			this.label4.TextAlign = ContentAlignment.MiddleCenter;
			this.label5.BorderStyle = BorderStyle.FixedSingle;
			this.label5.Font = new Font("Arial", 9f, FontStyle.Bold, GraphicsUnit.Point, 0);
			this.label5.Location = new Point(292, 48);
			this.label5.Name = "label5";
			this.label5.Size = new Size(102, 36);
			this.label5.TabIndex = 76;
			this.label5.Text = "Đơn vị tính";
			this.label5.TextAlign = ContentAlignment.MiddleCenter;
			this.label6.BorderStyle = BorderStyle.FixedSingle;
			this.label6.Font = new Font("Arial", 9f, FontStyle.Bold, GraphicsUnit.Point, 0);
			this.label6.Location = new Point(392, 48);
			this.label6.Name = "label6";
			this.label6.Size = new Size(121, 36);
			this.label6.TabIndex = 77;
			this.label6.Text = "Nước sản xuất";
			this.label6.TextAlign = ContentAlignment.MiddleCenter;
			this.label7.BorderStyle = BorderStyle.FixedSingle;
			this.label7.Font = new Font("Arial", 9f, FontStyle.Bold, GraphicsUnit.Point, 0);
			this.label7.Location = new Point(512, 48);
			this.label7.Name = "label7";
			this.label7.Size = new Size(101, 36);
			this.label7.TabIndex = 78;
			this.label7.Text = "Số lô";
			this.label7.TextAlign = ContentAlignment.MiddleCenter;
			this.label8.BorderStyle = BorderStyle.FixedSingle;
			this.label8.Font = new Font("Arial", 9f, FontStyle.Bold, GraphicsUnit.Point, 0);
			this.label8.Location = new Point(612, 48);
			this.label8.Name = "label8";
			this.label8.Size = new Size(81, 36);
			this.label8.TabIndex = 79;
			this.label8.Text = "Hạn sử dụng";
			this.label8.TextAlign = ContentAlignment.MiddleCenter;
			this.label9.BorderStyle = BorderStyle.FixedSingle;
			this.label9.Font = new Font("Arial", 9f, FontStyle.Bold, GraphicsUnit.Point, 0);
			this.label9.Location = new Point(692, 48);
			this.label9.Name = "label9";
			this.label9.Size = new Size(121, 36);
			this.label9.TabIndex = 80;
			this.label9.Text = "Nhận xét cảm quan";
			this.label9.TextAlign = ContentAlignment.MiddleCenter;
			this.label10.BorderStyle = BorderStyle.FixedSingle;
			this.label10.Font = new Font("Arial", 9f, FontStyle.Bold, GraphicsUnit.Point, 0);
			this.label10.Location = new Point(812, 48);
			this.label10.Name = "label10";
			this.label10.Size = new Size(81, 36);
			this.label10.TabIndex = 81;
			this.label10.Text = "Ghi chú";
			this.label10.TextAlign = ContentAlignment.MiddleCenter;
			this.btnPrint.Anchor = (AnchorStyles.Bottom | AnchorStyles.Left);
			this.btnPrint.Font = new Font("Arial", 9f, FontStyle.Bold, GraphicsUnit.Point, 163);
			this.btnPrint.Location = new Point(211, 564);
			this.btnPrint.Name = "btnPrint";
			this.btnPrint.Size = new Size(111, 30);
			this.btnPrint.TabIndex = 82;
			this.btnPrint.Text = "In báo cáo [ F7 ]";
			this.btnPrint.UseVisualStyleBackColor = true;
			this.btnPrint.Click += new EventHandler(this.btnPrint_Click);
			this.btnExportToExcel.Anchor = (AnchorStyles.Bottom | AnchorStyles.Left);
			this.btnExportToExcel.Font = new Font("Arial", 9f, FontStyle.Bold, GraphicsUnit.Point, 163);
			this.btnExportToExcel.Location = new Point(324, 564);
			this.btnExportToExcel.Name = "btnExportToExcel";
			this.btnExportToExcel.Size = new Size(78, 30);
			this.btnExportToExcel.TabIndex = 83;
			this.btnExportToExcel.Text = "Xuất Excel";
			this.btnExportToExcel.UseVisualStyleBackColor = true;
			this.btnExportToExcel.Click += new EventHandler(this.btnExportToExcel_Click);
			this.DateInput.AutoSizeMode = DataGridViewAutoSizeColumnMode.None;
			this.DateInput.DataPropertyName = "DateInput";
			dataGridViewCellStyle2.Format = "D";
			dataGridViewCellStyle2.NullValue = null;
			this.DateInput.DefaultCellStyle = dataGridViewCellStyle2;
			this.DateInput.HeaderText = "Ngày";
			this.DateInput.MinimumWidth = 84;
			this.DateInput.Name = "DateInput";
			this.DateInput.ReadOnly = true;
			this.DateInput.Width = 84;
			this.Row_Index.AutoSizeMode = DataGridViewAutoSizeColumnMode.None;
			this.Row_Index.DataPropertyName = "Row_Index";
			this.Row_Index.HeaderText = "STT";
			this.Row_Index.MinimumWidth = 50;
			this.Row_Index.Name = "Row_Index";
			this.Row_Index.ReadOnly = true;
			this.Row_Index.Width = 50;
			this.productName.AutoSizeMode = DataGridViewAutoSizeColumnMode.None;
			this.productName.DataPropertyName = "productName";
			this.productName.HeaderText = "Thuốc";
			this.productName.MinimumWidth = 150;
			this.productName.Name = "productName";
			this.productName.ReadOnly = true;
			this.productName.Width = 150;
			this.unitName.AutoSizeMode = DataGridViewAutoSizeColumnMode.None;
			this.unitName.DataPropertyName = "unitName";
			this.unitName.HeaderText = "Đơn vị tính";
			this.unitName.MinimumWidth = 100;
			this.unitName.Name = "unitName";
			this.unitName.ReadOnly = true;
			this.Name1.AutoSizeMode = DataGridViewAutoSizeColumnMode.None;
			this.Name1.DataPropertyName = "Name";
			this.Name1.HeaderText = "Nơi sản xuất";
			this.Name1.MinimumWidth = 120;
			this.Name1.Name = "Name1";
			this.Name1.ReadOnly = true;
			this.Name1.Width = 120;
			this.Packet.AutoSizeMode = DataGridViewAutoSizeColumnMode.None;
			this.Packet.DataPropertyName = "Packet";
			this.Packet.HeaderText = "Số lô";
			this.Packet.MinimumWidth = 100;
			this.Packet.Name = "Packet";
			this.Packet.ReadOnly = true;
			this.ProductExpiryDate.AutoSizeMode = DataGridViewAutoSizeColumnMode.None;
			this.ProductExpiryDate.DataPropertyName = "ProductExpiryDate";
			dataGridViewCellStyle3.Format = "D";
			dataGridViewCellStyle3.NullValue = null;
			this.ProductExpiryDate.DefaultCellStyle = dataGridViewCellStyle3;
			this.ProductExpiryDate.HeaderText = "HSD";
			this.ProductExpiryDate.MinimumWidth = 80;
			this.ProductExpiryDate.Name = "ProductExpiryDate";
			this.ProductExpiryDate.ReadOnly = true;
			this.ProductExpiryDate.Width = 80;
			this.Comnent.AutoSizeMode = DataGridViewAutoSizeColumnMode.None;
			this.Comnent.DataPropertyName = "Comnent";
			this.Comnent.HeaderText = "NX cảm quan";
			this.Comnent.MinimumWidth = 120;
			this.Comnent.Name = "Comnent";
			this.Comnent.ReadOnly = true;
			this.Comnent.Width = 120;
			this.Note.AutoSizeMode = DataGridViewAutoSizeColumnMode.None;
			this.Note.DataPropertyName = "Note";
			this.Note.HeaderText = "Ghi chú";
			this.Note.MinimumWidth = 80;
			this.Note.Name = "Note";
			this.Note.ReadOnly = true;
			this.Note.Width = 80;
			this.Pid.AutoSizeMode = DataGridViewAutoSizeColumnMode.None;
			this.Pid.DataPropertyName = "Pid";
			this.Pid.HeaderText = "Column10";
			this.Pid.Name = "Pid";
			this.Pid.ReadOnly = true;
			this.Pid.Visible = false;
			this.Pid.Width = 5;
			this.Column1.AutoSizeMode = DataGridViewAutoSizeColumnMode.Fill;
			this.Column1.HeaderText = "Column1";
			this.Column1.Name = "Column1";
			this.Column1.ReadOnly = true;
			base.AutoScaleDimensions = new SizeF(7f, 15f);
			//base.AutoScaleMode = AutoScaleMode.Font;
			base.ClientSize = new Size(900, 600);
			base.Controls.Add(this.btnExportToExcel);
			base.Controls.Add(this.btnPrint);
			base.Controls.Add(this.label10);
			base.Controls.Add(this.label9);
			base.Controls.Add(this.label8);
			base.Controls.Add(this.label7);
			base.Controls.Add(this.label6);
			base.Controls.Add(this.label5);
			base.Controls.Add(this.label4);
			base.Controls.Add(this.label3);
			base.Controls.Add(this.label2);
			base.Controls.Add(this.label1);
			base.Controls.Add(this.btnDelete);
			base.Controls.Add(this.btnAdd);
			base.Controls.Add(this.btnClose);
			base.Controls.Add(this.dgvProduct);
			this.Font = new Font("Arial", 9f, FontStyle.Regular, GraphicsUnit.Point, 0);
			//base.Icon = (System.Drawing.Icon)componentResourceManager.GetObject("$this.Icon");
			base.KeyPreview = true;
			base.Name = "frmTraceQuantity";
			base.ShowInTaskbar = false;
			base.StartPosition = FormStartPosition.CenterScreen;
			this.Text = "SỔ KIỂM SOÁT CHẤT LƯỢNG THUỐC";
			base.Load += new EventHandler(this.frmTraceQuantity_Load);
			base.KeyDown += new KeyEventHandler(this.frmTraceQuantity_KeyDown);
			((ISupportInitialize)this.dgvProduct).EndInit();
			base.ResumeLayout(false);
		}
		public frmTraceQuantity()
		{
			Program.strConnectionString = this.objFunc.strConnectionString;
			this.InitializeComponent();
		}
		private void btnClose_Click(object sender, EventArgs e)
		{
			base.Close();
		}
		private void btnAdd_Click(object sender, EventArgs e)
		{
			new frmAddTraceQuantity
			{
				userName = this.userName
			}.ShowDialog();
			this.getData();
		}
		private void frmTraceQuantity_Load(object sender, EventArgs e)
		{
			this.getData();
		}
		private void getData()
		{
			this.objTable = new DataTable();
			this.dgvProduct.AutoGenerateColumns = false;
			SqlConnection sqlConnection = new SqlConnection(Program.strConnectionString);
			string cmdText = "SELECT [DateInput], [Pid], [productName], [unitName], [Packet], [ProductExpiryDate], [Name] , [Comnent] , [Note], ROW_NUMBER() OVER(ORDER BY DateInput DESC) AS Row_Index FROM [TabTraceQuantity],[TabNational] WHERE [TabTraceQuantity].[NationalID] = [TabNational].[ID]";
			SqlCommand selectCommand = new SqlCommand(cmdText, sqlConnection);
			SqlDataAdapter sqlDataAdapter = new SqlDataAdapter(selectCommand);
			DataSet dataSet = new DataSet();
			sqlConnection.Open();
			sqlDataAdapter.Fill(dataSet);
			this.objTable = dataSet.Tables[0];
			this.dgvProduct.DataSource = dataSet.Tables[0];
			sqlConnection.Close();
			sqlConnection.Dispose();
			sqlDataAdapter.Dispose();
			dataSet.Dispose();
		}
		private void btnUpdate_Click(object sender, EventArgs e)
		{
			this.getData();
		}
		private void dgvProduct_CellClick(object sender, DataGridViewCellEventArgs e)
		{
			this.currPid = this.dgvProduct.Rows[e.RowIndex].Cells["PID"].Value.ToString();
			this.currPacket = this.dgvProduct.Rows[e.RowIndex].Cells["Packet"].Value.ToString();
		}
		private void dgvProduct_CellEnter(object sender, DataGridViewCellEventArgs e)
		{
			this.currPid = this.dgvProduct.Rows[e.RowIndex].Cells["PID"].Value.ToString();
			this.currPacket = this.dgvProduct.Rows[e.RowIndex].Cells["Packet"].Value.ToString();
		}
		private void btnDelete_Click(object sender, EventArgs e)
		{
			if (this.currPid != "" && this.currPacket != "")
			{
				if (MessageBox.Show("Bạn có muốn xoá bỏ mục này không?", "Thông báo", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.Yes)
				{
					SqlConnection sqlConnection = new SqlConnection(Program.strConnectionString);
					sqlConnection.Open();
					string cmdText = string.Concat(new string[]
					{
						"DELETE FROM [TabTraceQuantity] WHERE [Pid] = ",
						this.currPid,
						" AND [Packet] = '",
						this.currPacket,
						"'"
					});
					SqlCommand sqlCommand = new SqlCommand(cmdText, sqlConnection);
					sqlCommand.ExecuteNonQuery();
					sqlConnection.Close();
					sqlConnection.Dispose();
					this.getData();
				}
			}
		}
		private void frmTraceQuantity_KeyDown(object sender, KeyEventArgs e)
		{
			if (e.KeyCode == Keys.F4)
			{
				this.btnAdd.PerformClick();
			}
			else
			{
				if (e.KeyCode == Keys.F8)
				{
					this.btnDelete.PerformClick();
				}
				else
				{
					if (e.KeyCode == Keys.F7)
					{
						this.btnPrint.PerformClick();
					}
					else
					{
						if (e.KeyCode == Keys.Escape)
						{
							this.btnClose.PerformClick();
						}
					}
				}
			}
		}
		private void btnPrint_Click(object sender, EventArgs e)
		{
			frmTraceQuantityView frmTraceQuantityView = new frmTraceQuantityView();
			frmTraceQuantityVPrint.objTable = this.objTable;
			frmTraceQuantityView.ShowDialog();
		}
		private void btnExportToExcel_Click(object sender, EventArgs e)
		{
			try
			{
				frmTraceQuantityVPrint.objTable = new DataTable();
				frmTraceQuantityVPrint.objTable = this.objTable;
				ActiveReport3 activeReport = new frmTraceQuantityVPrint();
				activeReport.Run();
				XlsExport xlsExport = new XlsExport();
				SaveFileDialog saveFileDialog = new SaveFileDialog();
				saveFileDialog.ShowDialog();
				string text = saveFileDialog.FileName;
				if (text != "")
				{
					if (!text.ToUpper().Contains(".XLS"))
					{
						text += ".xls";
					}
					xlsExport.Export(activeReport.Document, text);
					MessageBox.Show("Hệ thống đã hoàn thành việc xuất dữ liệu ra file Excel", "Thông báo", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);
				}
				else
				{
					MessageBox.Show("Bạn chưa chọn đường dẫn và tên file cần xuất!", "Thông báo", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
				}
			}
			catch
			{
			}
		}
	}
}
